Skip to content

feat: add contains() method to DynamicArray#7270

Open
Neha-2005-VCE wants to merge 4 commits intoTheAlgorithms:masterfrom
Neha-2005-VCE:feat-add-contains-dynamicarray
Open

feat: add contains() method to DynamicArray#7270
Neha-2005-VCE wants to merge 4 commits intoTheAlgorithms:masterfrom
Neha-2005-VCE:feat-add-contains-dynamicarray

Conversation

@Neha-2005-VCE
Copy link

Added contains(E element) method to DynamicArray.

  • Uses Objects.equals for null-safe comparison
  • Iterates only over active elements (size)
  • Added unit tests including null case

@codecov-commenter
Copy link

codecov-commenter commented Feb 15, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.32%. Comparing base (c8d0291) to head (ad88ef8).

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #7270      +/-   ##
============================================
- Coverage     79.32%   79.32%   -0.01%     
- Complexity     6989     6992       +3     
============================================
  Files           781      781              
  Lines         22958    22962       +4     
  Branches       4510     4511       +1     
============================================
+ Hits          18212    18214       +2     
- Misses         4019     4020       +1     
- Partials        727      728       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Neha-2005-VCE Neha-2005-VCE force-pushed the feat-add-contains-dynamicarray branch from e3a8706 to ad88ef8 Compare February 17, 2026 15:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants